Skip to main content
GET
/
rag
/
{rag_id}
/
retrieve
/
Retrieve
curl --request GET \
  --url https://rag-prod.studio.lyzr.ai/v3/rag/{rag_id}/retrieve/ \
  --header 'x-api-key: <api-key>'
"<string>"

Authorizations

x-api-key
string
header
required

Path Parameters

rag_id
string
required

The unique identifier (ID) of the RAG system to query (must be a 24-character hex string).

Example:

"654c602a46c3b6d4e28741b0"

Query Parameters

query
string
required

The search query string used to retrieve documents.

Example:

"type the necessary query"

top_k
integer
required

The maximum number of top relevant documents to return.

Example:

10

lambda_param
number
required

Factor for Maximum Marginal Relevance (MMR) trade-off (0.0 to 1.0).

Example:

0.6

retrieval_type
enum<string>
required

The retrieval strategy to use.

Available options:
basic,
mmr,
hyde,
time_aware
Example:

"basic"

score_threshold
number
required

Minimum score required for a document to be included (0.0 to 1.0).

Example:

0

time_decay_factor
number
required

Factor for time-aware retrieval to weight newer documents higher.

Example:

0.7

Response

Documents successfully retrieved.

Placeholder for the retrieved document structure (typically a list of Document objects with relevance scores).